{% block title %}Create an account{% endblock %}

{% block content %}
  <h1>Create an account</h1>
  
  {% if error %}
  <br>
{{ error }}
<br>
{% endif %}
  
  <form action="/museumweb/mainpage/register/" method="post">
  {% csrf_token %}
   {{ form.non_field_errors }} 
    
    
    {{ form.user.errors }}
      {{ form.username.errors }}
    <label for="id_username">Username:</label> {{ form.username }}

	<br>
      {{ form.password.errors }}
  		
    <label for="id_password">Password:</label> {{ form.password }}

 	<br>  
      {{ form.email.errors }}
    <label for="id_email">Email: </label>{{ form.email }}

<br>  
      {{ form.first.errors }}
    <label for="id_first">First Name: </label>{{ form.first }}
    
    <br>  
      {{ form.last.errors }}
    <label for="id_last">Last Name: </label>{{ form.last }}
    
    <br>  
      {{ form.code.errors }}
    <label for="id_code">Registration Code: </label>{{ form.code }}
    
    
    <input type="submit" value="Create the account" />
   </form>
{% endblock %}